"""
Project Name : api_automation_framework
File Name : cookies-set-name-value.py
Author : lldhsds
Date : 2024/12/29 11:32
Description: /cookies/set/{name}/{vaule}, Sets a cookie and redirects to cookie list.
"""

import requests

def cookies_set_name_vaule(name: str, value: str) -> None:
    url = f'https://httpbin.org/cookies/set/{name}/{value}'
    headers = {'Accept': 'text/plain'}
    response = requests.get(url, headers=headers)
    print(response.status_code)
    print(response.json())
    print(response.headers)

cookies_set_name_vaule('freeform', 'abc123')
